<?php
	include $script['classConnexion'];
	$laBase = new clstBDD;
	$laBase->connecte($db ['dsn'],$db ['userid'],$db ['pass']);
	
	if ($laBase->getConnexion() != null) {
		//on interroge la base
		$sql='select pra_nom,pra_num from praticien';
		$curseur = $laBase->requeteSelect($sql);
		$res=mysql_fetch_array($curseur);
		list($err, $donneesPraticiens) = obtenirDonnees($db ['dsn'],$db ['userid'],$db ['pass'], $sql);
		
		$laBase = new clstBDD;
		$laBase->connecte($db ['dsn'],$db ['userid'],$db ['pass']);
		
		$sql2 = 'select med_nomcommercial,med_depotlegal from medicament';
		$curseur2 = $laBase->requeteSelect($sql2);
		$res2 = mysql_fetch_array($curseur2);
		list($err, $donneesMedicaments) = obtenirDonnees($db ['dsn'],$db ['userid'],$db ['pass'], $sql2);
		
		$laBase = new clstBDD;
		$laBase->connecte($db ['dsn'],$db ['userid'],$db ['pass']);
		
		$sql3='select count(*) as num_rap from rapport_visite';
		$curseur3 = $laBase->requeteSelect($sql3);
		$res3=mysql_fetch_array($curseur3);
		$res3["num_rap"] = $res3["num_rap"] + 1;
	}
	
	$contenu = $page['FormRapportVisite'];
	$title = 'Form Rapport Visite';
?>